import { MediaCodec, Router, TransportOptions, WebRtcTransport, Worker } from 'mediasoup'
import { PaymentIntent, PaymentIntentList } from 'stripe'
import { Config as MediaServerConfig, NodeMediaServer, Session } from './node-media-server'
import { AuthenticatedSocket, ChatMessage, GameSocket, GameState } from './socket'

export {
  // Socket types
  AuthenticatedSocket,
  ChatMessage,
  GameSocket,
  GameState,
  // Mediasoup types
  MediaCodec,
  // Media server types
  MediaServerConfig,
  NodeMediaServer,
  // Stripe types
  PaymentIntent,
  PaymentIntentList,
  Router,
  Session,
  TransportOptions,
  WebRtcTransport,
  Worker,
}

export interface ApiResponse<T = any> {
  status: 'success' | 'error'
  message?: string
  data?: T
  error?: {
    code: number
    message: string
  }
}
